{template header}
<div class="mainFrame">
	<div class="order-tab-bar">
    	<div class="item{if !$status} on{/if}"><a href="/?m=$G[m]&c=$G[c]">全部记录</a></div>
        <div class="item{if $status==1} on{/if}"><a href="/?m=$G[m]&c=$G[c]&status=1">进行中</a></div>
        <div class="item{if $status==2} on{/if}"><a href="/?m=$G[m]&c=$G[c]&status=2">已完成</a></div>
        <div class="item"><a href="/?m=$G[m]&c=$G[c]&a=newticket">添加返券</a></div>
    </div>
    {if $recordlist}
    <table cellpadding="0" cellspacing="0" width="100%" class="ticket-table">
    	<thead>
        	<tr>
                <th>返券号</th>
                <th width="100">商家</th>
                <th width="80">返利金额</th>
                <th width="80">已完成</th>
                <th width="140">发放时间</th>
                <th width="60">状态</th>
            </tr>
        </thead>
        <tbody>
        	{loop $recordlist $record}
        	<tr>
            	<td class="no">$record[ticket_sn]</td>
                <td>星微超市</td>
                <td>￥:{echo @number_format($record[ticket_amount],2)}</td>
                <td>￥:{echo @number_format($record[ticket_complete],2)}</td>
                <td>{echo @date('Y-m-d H:i:s', $record[dateline])}</td>
                <td>已完成</td>
            </tr>
            {/loop}
        </tbody>
    </table>
    {else}
    <div class="noaccess">
    	你还没有获得过任何分红，立即<a href="/?m=market">购物拿分红</a>。
    </div>
    {/if}
</div>
{template footer}